<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Login - Bukaka Inti - An Airconditioning Company</title>
	<link rel="stylesheet" type="text/css" href="../themes/default/easyui.css">
	<link rel="stylesheet" type="text/css" href="../themes/icon.css">
	<script type="text/javascript" src="../js/jquery-1.7.1.min.js"></script>
	<script type="text/javascript" src="../js/jquery.easyui.min.js"></script>
	<script type="text/javascript">
            function forget(){
                $('#d2').dialog('close');
                $.messager.prompt('Lupa Password', 'Username', function(r){
                    if (r){
                        $.post('forget.php', {username:r}, function(result){
                                var result = eval('('+result+')');
                                if (result.success){
                                    $.messager.alert('Sukses','Silahkan cek email Anda!','info',function(b){
                                        document.location.href='../';
                                    });
                                } else {
                                    $.messager.show({
                                        title: 'Error',
                                        msg: result.msg
                                    });
                                }
                        });
                    } else {
                    document.location.href='../';
                    }
                });
            }
            $(function(){
            $('#username').focus();
            });
	</script>
        <style type="text/css">
            label{
                font-size: 15px;
                width:80px;
                display:inline-block;
            }
        </style>
</head>
<body>
	<div id="d2" 
             class="easyui-dialog" 
             title="Login"
             closable="false"
             style="width:auto;height:auto;padding:10px;"
             resizable="true">
            <form id="ff" method="post" action="login.php">
                <label>Username</label><Input id="username" class="easyui-validatebox" name="username" required><br>
                <label>Password</label><Input class="easyui-validatebox" name="password" type="password" required><br>
		<a href="#" onclick="forget()" style="float:left;text-decoration: none;padding-top: 5px">Lupa password?</a>
                <input type="submit" value="Login" style="float:right;text-decoration: none">
            </form>
	</div>
</body>
</html>
